package main

import "fmt"

type Person struct {
	Name string
}

func test02(p *Person) {
	fmt.Println(p.Name)
}

func (p Person) test03() {
	p.Name = "jack"
	fmt.Println("test03() =", p.Name)
}

func main() {

	p := Person{"tom"}
	test02(&p)
	p.test03()
	fmt.Println("main() p.name =", p.Name)
	(&p).test03()
	fmt.Println("main() p.name =", p.Name)

}